Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

197
Vistas
filter with req.query and I had : "error_message": "Key \"name\" required but not present." in POSTMAN

Hello I had this error since yesterday and I coudn't solve it ! I did not know the problem where : the error : "error_message": "Key "name" required but not present." in POSTMAN the code :

// ``` routes :

app.get('/v1/sites/:site_id/balise',
blueprintValidator.uriValidator,
baliseController.getByBaliseName.bind(baliseController),
sendJSON

)``` // balise-controller :

  const baliseName = req.query.name
  console.log(baliseName)
  try {
    const balise = await Balise.getByName(baliseName)

    if (!balise) {
      return next(new ResourceNotFoundError(req, res, 'No balise found for this name.'))
    }
    res.locals.data = balise
    next()
  } catch (next) {

  }
}```

// balise - model : 


```Balise.getByName = async function (baliseName) {
  console.log('aabbab')
  return await new Balise({ name: baliseName }).fetch()
}```

// balise - doc file : 

## Filter balises [/v1/sites/{site_id}/balise{?name}]

+ Parameters
  + site_id: `` (integer) ... id of the Site
  + name: `` (string)

### balise [GET]

+ Response 200 (application/json)

  JSON representation of Balise Collection Resource. The Balise resources in collections are embedded.

  + Body

            
                {
                  "id": 2,
                  "equipment_id": 1,
                  "name": "Balise2",
                  "operating_mode": "IN",
                  "power_ble": 40,
                  "latitude": 45.718416666667,
                  "longitude": 5.0804166666667
                }
  
about 4 years ago · Santiago Trujillo
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda